package ykc.demo.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

import javax.servlet.http.HttpSession;

@Controller
public class LController {

    @RequestMapping("/input")
    public String input(){ return "login"; }

    @RequestMapping("/check")
    public String login(HttpSession session, String username, String pass){
        session.setAttribute("username",username);
        return "redirect:/";
    }
}
